Set Hostname
2017/07/16 |
This is the example for setting Hostname of your system.
|
|
[1] | Change hostname. (but if system restarted, it will be back). |
# change hostname [root@localhost ~]# hostname dlp.srv.world [root@localhost ~]# dlp.srv.world # just changed |
[2] | Change hostname permanently. |
[root@localhost ~]#
hostnamectl set-hostname dlp.srv.world # show state [root@localhost ~]# Static hostname: dlp.srv.world Icon name: computer-vm Chassis: vm Machine ID: a9441a005b55452987f2a588f9369b85 Boot ID: 0c948f4a19694d0291e6c25e1095218f Virtualization: kvm Operating System: Fedora 26 (Server Edition) CPE OS Name: cpe:/o:fedoraproject:fedora:26 Kernel: Linux 4.11.9-300.fc26.x86_64 Architecture: x86-64 |